package cn.itsource.domain;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.enums.IdType;
import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;
import org.springframework.data.annotation.Transient;

import java.io.Serializable;

/**
 * <p>
 * 套餐表
 * </p>
 *
 * @author bobo
 * @since 2022-12-18
 */
@TableName("t_combo")
public class Combo extends Model<Combo> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    /**
     * 套餐类型
     */
    //@Transient 标注该字段不予数据库做映射
    //@TableField(exist = false)
    private String name;
    /**
     * 1,包月 2,包季 3包年 
     */
    private Integer month;
    /**
     * 逻辑删除字段 0未删除 1已删除
     */
    private Boolean del;
    /**
     * 折扣
     */
    private BigDecimal discount;


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getMonth() {
        return month;
    }

    public void setMonth(Integer month) {
        this.month = month;
    }

    public Boolean getDel() {
        return del;
    }

    public void setDel(Boolean del) {
        this.del = del;
    }

    public BigDecimal getDiscount() {
        return discount;
    }

    public void setDiscount(BigDecimal discount) {
        this.discount = discount;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "Combo{" +
        ", id=" + id +
        ", name=" + name +
        ", month=" + month +
        ", del=" + del +
        ", discount=" + discount +
        "}";
    }
}
